home *** CD-ROM | disk | FTP | other *** search
Perl Script | 1995-05-04 | 468 b | 21 lines | [TEXT/MPS ] |
- #! /usr/unsupported/bin/perl
- foreach $file (<*.imf>) {
- open(IMF,"<$file") || warn "Cannot open $file.\n";
- while (<IMF>) {
- if (/imf\s*\"([^\"]*)\"/) {
- $imf = $1;
- if ($where{$imf} && $where{$imf} ne $file) {
- warn "Family $imf present in files $where{$imf} and $file.\n";
- } else {
- $where{$imf} = $file;
- }
- }
- }
- }
-
- print "ImageFamilyName FileName\n";
- foreach $imf (sort keys(%where)) {
- print "$imf $where{$imf}\n";
- }
- print ". .\n";
-